package com.liohi.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import lombok.Data;

/**
 * 
 * @TableName experiments
 */
@TableName(value ="experiments")
@Data
public class Experiments implements Serializable {
    /**
     * 
     */
    @TableId(value = "experiments_id", type = IdType.AUTO)
    private Integer experimentsId;

    /**
     * 
     */
    @TableField(value = "resources_id")
    private Integer resourcesId;

    /**
     * 
     */
    @TableField(value = "resource_name")
    private String resourceName;

    /**
     * 
     */
    @TableField(value = "number")
    private String number;

    /**
     * 
     */
    @TableField(value = "breif_intro")
    private String breifIntro;

    /**
     * 
     */
    @TableField(value = "class_hours")
    private Integer classHours;

    /**
     * 
     */
    @TableField(value = "course_number")
    private String courseNumber;

    /**
     * 
     */
    @TableField(value = "imgUrl")
    private String imgurl;

    /**
     * 
     */
    @TableField(value = "intro")
    private String intro;

    /**
     * 
     */
    @TableField(value = "create_time")
    private LocalDateTime createTime;

    /**
     * 
     */
    @TableField(value = "rs_ids")
    private String rsIds;

    /**
     * 用户类型 1老师 2学生 3社会人士
     */
    @TableField(value = "type")
    private String type;

    /**
     * 
     */
    @TableField(value = "update_time")
    private LocalDateTime updateTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Experiments other = (Experiments) that;
        return (this.getExperimentsId() == null ? other.getExperimentsId() == null : this.getExperimentsId().equals(other.getExperimentsId()))
            && (this.getResourcesId() == null ? other.getResourcesId() == null : this.getResourcesId().equals(other.getResourcesId()))
            && (this.getResourceName() == null ? other.getResourceName() == null : this.getResourceName().equals(other.getResourceName()))
            && (this.getNumber() == null ? other.getNumber() == null : this.getNumber().equals(other.getNumber()))
            && (this.getBreifIntro() == null ? other.getBreifIntro() == null : this.getBreifIntro().equals(other.getBreifIntro()))
            && (this.getClassHours() == null ? other.getClassHours() == null : this.getClassHours().equals(other.getClassHours()))
            && (this.getCourseNumber() == null ? other.getCourseNumber() == null : this.getCourseNumber().equals(other.getCourseNumber()))
            && (this.getImgurl() == null ? other.getImgurl() == null : this.getImgurl().equals(other.getImgurl()))
            && (this.getIntro() == null ? other.getIntro() == null : this.getIntro().equals(other.getIntro()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getRsIds() == null ? other.getRsIds() == null : this.getRsIds().equals(other.getRsIds()))
            && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getExperimentsId() == null) ? 0 : getExperimentsId().hashCode());
        result = prime * result + ((getResourcesId() == null) ? 0 : getResourcesId().hashCode());
        result = prime * result + ((getResourceName() == null) ? 0 : getResourceName().hashCode());
        result = prime * result + ((getNumber() == null) ? 0 : getNumber().hashCode());
        result = prime * result + ((getBreifIntro() == null) ? 0 : getBreifIntro().hashCode());
        result = prime * result + ((getClassHours() == null) ? 0 : getClassHours().hashCode());
        result = prime * result + ((getCourseNumber() == null) ? 0 : getCourseNumber().hashCode());
        result = prime * result + ((getImgurl() == null) ? 0 : getImgurl().hashCode());
        result = prime * result + ((getIntro() == null) ? 0 : getIntro().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getRsIds() == null) ? 0 : getRsIds().hashCode());
        result = prime * result + ((getType() == null) ? 0 : getType().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", experimentsId=").append(experimentsId);
        sb.append(", resourcesId=").append(resourcesId);
        sb.append(", resourceName=").append(resourceName);
        sb.append(", number=").append(number);
        sb.append(", breifIntro=").append(breifIntro);
        sb.append(", classHours=").append(classHours);
        sb.append(", courseNumber=").append(courseNumber);
        sb.append(", imgurl=").append(imgurl);
        sb.append(", intro=").append(intro);
        sb.append(", createTime=").append(createTime);
        sb.append(", rsIds=").append(rsIds);
        sb.append(", type=").append(type);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}